<br />

<?php foreach ($mat as $m):?>
<div style="float: left; margin: 1px; padding: 2px; border: 1px solid silver">
<?php echo link_to(image_tag('/uploads/material/gallery/_thumbnail/'.$m->getMaterialRelatedByToId()->getPhotoPath()),'material/edit?id='.$m->getToId()) ?>
<br /><?php echo link_to(__('Удалить'),'material/edit?del_to_mat=true&id='.$m->getFromId().'&id_mat='.$m->getToId(),array('confirm'=>__('Вы уверены?'),'style'=>'color: red', 'class'=>'size10'))?>
</div>
<?php endforeach ?>
